<template>
	<view>
		<view class="gifts-list" v-if="opt == null">
			<view class="gifts-pic"><image style="width: 100%; height: 100%;" src="../../static/nzb.png"></image><view class="gifts-number">10</view></view>
			<view class="gifts-name">你真棒</view>
		</view>
		<view class="gifts-list" v-else>
			<view class="gifts-pic"><image style="width: 100%; height: 100%;" :src="opt.gift_icon"></image><view class="gifts-number">{{opt.user_cpt_temp.coins}}</view></view>
			<view class="gifts-name">{{opt.nick_name}}</view>
		</view>
	</view>
</template>

<script>
	export default {
		name:"gift",
		props: {
			opt: Object,
			default: null
		},
		data() {
			return {
				
			};
		}
	}
</script>

<style scoped>

.gifts-list {
	flex: 1;
	display: flex;
	flex-direction: column;
	align-items: center;
	
}

.gifts-pic {
	width: 50px;
	height: 50px;
	position: relative;
}

.gifts-name {
	color: #fff;
	text-shadow: 0px 0px 4px rgba(0, 0, 0, 1);
	font-size: 15px;
	padding-top: 6px;
}

.gifts-number {
	position: absolute;
	right: 0;
	bottom: -6px;
	display: flex;
	background-color: rgba(0, 0, 0, 0.3);
	color: #fff;
	text-shadow: 0px 0px 4px rgba(0, 0, 0, 1);
	padding: 0 9px;
	border-radius: 15px;
	align-items: center;
	justify-content: center;
	font-size: 13px;
}
</style>